/*
 * VegetableSupplyInfoPanel.hpp
 *
 *  Created on: 09-01-2011
 *      Author: Piotr
 */

#pragma once

#include "SingleElementInfoPanel.hpp"
#include "world/VegetableSupply.hpp"
#include "gui/Label.hpp"

/*
 * Panel which contains info about a vegetable supply.
 */
class VegetableSupplyInfoPanel: public SingleElementInfoPanel
{
	private:
		const VegetableSupply* selected;

		Label* amountLabel;
		Label* toSpoilageLabel;

	public:
		VegetableSupplyInfoPanel(float parentWidth, const VegetableSupply* selected);
		std::string getSelectionName() const;

	protected:
		void createComponents(float parentWidth);
		const VegetableSupply* getSelected() const;
		void updateFromSelection();
};
